<div class="row">
     <div class="col-xs-12 col-xs-12">
          <div class="widget radius-bordered">
              <div class="widget-header bg-blue">
				<i class="widget-icon fa fa-arrow-down"></i>
				<span class="widget-caption">车辆编辑</span>
				<div class="widget-buttons">
					<a href="#" data-toggle="maximize">
						<i class="fa fa-expand"></i>
					</a>
					<a href="#" data-toggle="collapse">
						<i class="fa fa-minus"></i>
					</a>
					<a href="#" data-toggle="dispose">
						<i class="fa fa-times"></i>
					</a>
				</div>
			</div>
              <div class="widget-body">
                   <form id="YstechForm" action="" method="post" class="form-horizontal"
                                                  data-bv-message=""
                                                  data-bv-feedbackicons-valid="glyphicon glyphicon-ok"
                                                  data-bv-feedbackicons-invalid="glyphicon glyphicon-remove"
                                                  data-bv-feedbackicons-validating="glyphicon glyphicon-refresh">
                  <input type="hidden" name="carid" value="{$cache.carid}">
                  <div class="form-title">
                        <a href="{:U('Cms/Car/carList',array('p'=>$p))}" class="btn btn-primary" data-loader="Ystech-loader" data-loadername="车辆列表">
							<i class="fa fa-mail-reply"></i>返回
						</a>
                   </div>
				   <div class="form-group">
                        <label class="col-lg-2 control-label">车牌号<sup>*</sup></label>
                        <div class="col-lg-4">
                        <input type="hidden" name="carid" class="form-control" value="{$cache.carid}">
                        <input type="text" name="carnum" class="form-control" value="{$cache.carnum}">
                        </div>
                   </div>
				   <div class="form-group">
                        <label class="col-lg-2 control-label">类型<sup>*</sup></label>
                        <div class="col-lg-4">
                        <select name="type" class="form-control input-sm">
                            <option value='0' <if condition="$cache.type eq 0">selected</if>>公有</option>
                            <option value='1' <if condition="$cache.type eq 1">selected</if>>私有</option>
                        </select>
                        </div>
                   </div>
                   <div class="form-group">
                           <label class="col-lg-2 control-label">状态<sup>*</sup></label>
                           <div class="col-lg-4">
                               <select name="status" class="form-control input-sm">
                                   <option value='0' <if condition="$cache.type eq 0">selected</if>>正常</option>
                                   <option value='1' <if condition="$cache.type eq 1">selected</if>>不可用</option>
                               </select>
                           </div>
                       </div>
                       <div class="form-group">
                           <label class="col-lg-2 control-label">二维码地址<sup>*</sup></label>
                           <div class="col-lg-4">
                               <input type="text" name="qrcode" class="form-control" value="{$cache.qrcode}">
                           </div>
                           <a href="" style=" position:absolute;bottom:0;">获取最新二维码</a>
                       </div>
                       <div class="form-group">
                           <label class="col-lg-2 control-label">锁序列号<sup>*</sup></label>
                           <div class="col-lg-4">
                               <select name="lockid" class="form-control input-sm">
                                  <volist name="locks_list" id="vo">
                                     <option value='{$vo.ID}' <if condition="$cache['lockid'] eq $vo['ID']">selected</if>>{$vo.SerialNo}</option>
                                  </volist>
                               </select>
                           </div>
                       </div>
					<div class="form-group">
                        <div class="col-lg-offset-2 col-lg-4">
                             <button class="btn btn-primary btn-lg" type="submit">保存</button>&nbsp;&nbsp;&nbsp;&nbsp;
                             <button class="btn btn-palegreen btn-lg" type="reset">重填</button>
                        </div>
                    </div>
                   </form>
                </div>
        </div>
	</div>
     
</div>
<!--面包屑导航封装-->
<div id="tmpbread" style="display: none;">{$breadhtml}</div>
<script type="text/javascript">
	setBread($('#tmpbread').html());
</script>
<!--/面包屑导航封装-->

<!--表单验证与提交封装-->
<script type="text/javascript">

	$('#CreateDate').datepicker({format:"yyyy-mm-dd",autoclose:1});
	$('#ExpiryDate').datepicker({format:"yyyy-mm-dd",autoclose:1});

	$('#YstechForm').bootstrapValidator({
		submitHandler: function (validator, form, submitButton) {

			if(!$('input[name="carnum"]').val()){
				$.Ystech.alert('danger','请输入车牌号！');
				return false;
			}
			
           	var tourl="{:U('Cms/Car/cargoods')}";
			var data=$('#YstechForm').serialize();
			$.Ystech.ajax('post',tourl,data,null);
			return false;
        },
	});
	
	
</script>
<!--/表单验证与提交封装-->
